home *** CD-ROM | disk | FTP | other *** search
- #! /bin/sh
- #set -e
-
- . /usr/share/debconf/confmodule
-
- db_get languagechooser/language-name
- db_subst ubiquity/summary LANGUAGE "$RET"
- if db_get console-setup/variant && [ "$RET" ]; then
- db_subst ubiquity/summary KEYMAP "$RET"
- else
- db_get console-setup/layout
- db_subst ubiquity/summary KEYMAP "$RET"
- fi
- db_get passwd/user-fullname
- db_subst ubiquity/summary FULLNAME "$RET"
- db_get passwd/username
- db_subst ubiquity/summary USERNAME "$RET"
- db_get time/zone # actually continent/city (usually)
- db_subst ubiquity/summary LOCATION "$RET"
-
- # Migration Assistant
- db_capb escape
- ret=""
- newline='
- '
- db_get migration-assistant/partitions
- OLD_IFS="$IFS"
- IFS='
- '
- partitions="$(echo "$RET" | sed -e 's/, /\n/g')"
- for choice in $partitions; # Microsoft Windows XP Professional (/dev/hda1)
- do
- ret="$ret$choice:$newline"
- part="$(expr match "$choice" '.*/\(.*\))$')" # hda1
-
- db_get "migration-assistant/$part/users"
- if [ -z "$RET" ]; then
- ret="${ret}None$newline"
- fi
- users="$(echo "$RET" | sed -e 's/, /\n/g')"
- for user in $users; do
- ret="$ret$user: "
- formatted_user="$(echo "$user" | sed -e 's/ /:/g')"
- db_get "migration-assistant/$part/$formatted_user/items"
- ret="$ret$RET$newline"
- done
- ret="$ret$newline"
- done
- IFS="$OLD_IFS"
- db_subst ubiquity/summary MIGRATE "${ret%$newline}"
- db_capb
-
- # We need to run this to get hold of the partitioning summary. Our component
- # takes care of ensuring that changes are not actually committed.
- if [ "$PARTMAN_UPDATE_BEFORE_COMMIT" ]; then
- partman-commit || true
- fi
-
- db_capb escape
- db_get ubiquity/partman-made-changes
- if [ "$RET" = true ]; then
- db_metaget partman/confirm Extended_description
- else
- db_metaget partman/confirm_nochanges Extended_description
- fi
- db_subst ubiquity/summary PARTMAN_CHANGES \
- "$(printf %s "$RET" | debconf-escape -e)"
- db_capb
-
- db_input high ubiquity/summary || true
- db_go
-
- exit 0
-